package decorator;

import java.math.BigDecimal;

/**
 * 4. 装饰者实现类2
 */
public class CakeAddMangoDecorator extends CakeDecorator{
    public CakeAddMangoDecorator(Cake cake) {
        super(cake);
    }

    @Override
    public String getCakeMsg() {
        return super.getCakeMsg() + "加芒果";
    }

    @Override
    public BigDecimal getPrice() {
        return super.getPrice().add(new BigDecimal("15"));
    }
}
